<?php
/**
 * ===============================================
 * 版权所有 2019-2050 青岛铁锤科技有限公司，并保留所有权利。
 * 网站地址: http://www.huaxianling.com
 * ===============================================
 * Author: Happy dong
 * Created Time: 2019-07-24 14:10
 *
 * Version: 2.0
 */

namespace App\Modules\Message\Validators;


use Flower\Core\Repository\Contracts\ValidatorInterface;
use Flower\Core\Repository\Validator\LaravelValidator;
use Illuminate\Support\Facades\DB;

class MessageValidator extends LaravelValidator
{
	protected $rules = [
		ValidatorInterface::RULE_CREATE=>[
			'scene'          => 'required|numeric',
			'title'          => 'required|alpha_dash',
			'content'        => 'required'
		]
	];

	protected $messages = [
		'scene.required'      => '场景类型不能为空',
		'scene.numeric'       => '场景类型数据格式不对，必须为',
		'title.required'      => '消息标题，不能为空',
		'title.alpha_dash'   => '消息标题数据格式不对，可能具有字母、数字、破折号（ - ）以及下划线（ _ ）',
		'content.required'      => '消息内容，不能为空',
	];



}